package com.loongtech.bi.entity.player;

import com.loongtech.core.util.Time;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.io.Serializable;
import java.util.Date;

@Entity
@Table(name = "acu")
public class EntityAcu implements Serializable {
	private static final long serialVersionUID = 2L;

	@Id
	private Date day; // 日期
	@Id
	private String serverid;
	@Id
	private String channelid;
	@Id
	private String platformid;
	@Column(columnDefinition="bigint NOT NULL default 0")
	private long sumonlinenum;
	@Column(columnDefinition="bigint NOT NULL default 0")
	private long number;
	@Column(columnDefinition="bigint NOT NULL default 0")
	private long acu;

    public String getKey() {
        return Time.getDateStr(day) + "-" + platformid + "-" + channelid + "-" + serverid;
    }

    public Date getDay() {
		return day;
	}

	public void setDay(Date day) {
		this.day = day;
	}

	public String getServerid() {
		return serverid;
	}

	public void setServerid(String serverid) {
		this.serverid = serverid;
	}

	public String getChannelid() {
		return channelid;
	}

	public void setChannelid(String channelid) {
		this.channelid = channelid;
	}

	public String getPlatformid() {
		return platformid;
	}

	public void setPlatformid(String platformid) {
		this.platformid = platformid;
	}

	public long getSumonlinenum() {
		return sumonlinenum;
	}

	public void setSumonlinenum(long sumonlinenum) {
		this.sumonlinenum = sumonlinenum;
	}

	public long getNumber() {
		return number;
	}

	public void setNumber(long number) {
		this.number = number;
	}

	public long getAcu() {
		return acu;
	}

	public void setAcu(long acu) {
		this.acu = acu;
	}
}